package com.cmcc.linlaker.ui.upload;

import android.os.Bundle;
import android.os.Handler;
import android.support.v7.app.AppCompatActivity;
import android.view.KeyEvent;
import android.view.View;

import com.cmcc.linlaker.R;
import com.cmcc.linlaker.utils.BarUtils;
import com.cmcc.linlaker.utils.ToastUtils;

public class UploadSuccessActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_upload_success);

        BarUtils.initStatusBar(this);

        initView();
    }

    public void initView() {

    }

    /**
     * 继续上报
     */
    public void continueUpload(View view) {
        setResult(200);
        finish();
    }

    public void back(View view) {
        setResult(100);
        finish();
    }

    @Override
    public boolean onKeyDown(int keyCode, KeyEvent event) {
        if (keyCode == KeyEvent.KEYCODE_BACK && event.getRepeatCount() == 0) {
            setResult(100);
            finish();
            return true;
        }
        return super.onKeyDown(keyCode, event);
    }
}
